/*
 * Teknei 2014 - All rights reserved
 */
package com.teknei.acabus.core.entities;

import java.io.Serializable;
import javax.persistence.*;

/**
 * The persistent class for the "NAVIGATION_CHILD_ROLES" database table.
 * @author Jorge Amaro
 * @version 1.0
 * @since 1.0
 */
@Entity
@Table(name = "\"SITM_NAVIGATION_CHILD_ROLES\"")
@NamedQuery(name = "NavigationChildRole.findAll", query = "SELECT n FROM NavigationChildRole n")
public class NavigationChildRole implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@SequenceGenerator(name = "NAVIGATION_CHILD_ROLES_ID_GENERATOR", sequenceName = "\"NAVIGATION_CHILD_ROLES_id_seq\"")
	@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "NAVIGATION_CHILD_ROLES_ID_GENERATOR")
	private Integer id;

	// bi-directional many-to-one association to Role
	@ManyToOne
	@JoinColumn(name = "id_nav")
	private NavigationChild child;

	// bi-directional many-to-one association to Role
	@ManyToOne
	@JoinColumn(name = "id_role")
	private Role role;

	/**
	 * 
	 */
	public NavigationChildRole() {
	}

	/**
	 * @return
	 */
	public Integer getId() {
		return this.id;
	}

	/**
	 * @param id
	 */
	public void setId(Integer id) {
		this.id = id;
	}

	/**
	 * @return
	 */
	public Role getRole() {
		return this.role;
	}

	/**
	 * @param role
	 */
	public void setRole(Role role) {
		this.role = role;
	}

	/**
	 * @return the child
	 */
	public NavigationChild getChild() {
		return child;
	}

	/**
	 * @param child
	 *            the child to set
	 */
	public void setChild(NavigationChild child) {
		this.child = child;
	}

}